package com.njwb.thread;

/**
 * Description: 类的描述
 * Author: yuandeyin@itany.com
 * Date: 2025-08-06 16:04
 * Version: 1.0
 */
public class Totorise implements Runnable{
    private int step = 10;
    @Override
    public void run() {
        for(int i = 1; i <= step; i++){
            System.out.println(Thread.currentThread().getName() + "跑了第" + (i) + "步");
            try {
                Thread.sleep(1000);
            } catch (InterruptedException e) {
            }
        }
        System.out.println(Thread.currentThread().getName() + "到达终点");
    }
}
